package com.nbsaas.boot.product.rest.convert;

import com.nbsaas.boot.product.data.entity.ProductSpecificationValue;
import com.nbsaas.boot.product.api.domain.request.ProductSpecificationValueRequest;

import org.springframework.beans.BeanUtils;
import com.nbsaas.boot.rest.api.Converter;
import com.nbsaas.boot.utils.BeanDataUtils;

/**
* 商品规格值请求对象转换成实体对象
*/

public class ProductSpecificationValueEntityConvert  implements Converter<ProductSpecificationValue, ProductSpecificationValueRequest> {

    @Override
    public ProductSpecificationValue convert(ProductSpecificationValueRequest source) {
        ProductSpecificationValue result = new ProductSpecificationValue();
        BeanDataUtils.copyProperties(source, result);
        return result;
    }
}

